<ion-view view-title="单品库存分布" show-tabs>
  <ion-content class="inventory-detail">
		<ion-list class="wrap-light2">
			<ion-item class="item-base item-icon-right" href="">
		    <span class="list-label">型号</span>
		    <span class="royal">{{inventoryDetail.brand.name}}{{inventoryDetail.model}}</span>
        <i class="icon ion-ios-arrow-right"></i>
			</ion-item>
			
			<ion-item class="item-base">
		    <span class="list-label">存量</span>
		    <span>{{inventoryDetail.qty}} 部</span>
			</ion-item>
      <ion-item class="item-base">
        <span class="list-label">售价</span>
        <span>{{inventoryDetail.sale_price | currency:'￥' }}</span>
      </ion-item>
			<ion-item class="item-base">
		    <span class="list-label">总值</span>
		    <span>{{inventoryDetail.qty * inventoryDetail.min_sale_price | currency:'￥' }} ~ {{inventoryDetail.qty * inventoryDetail.sale_price | currency:'￥' }} </span>
			</ion-item>
    </ion-list>
    <ion-list class="accordion-list">
      <ion-item class="item-divider margin-top-large">
        库存分布
      </ion-item>

  		<ion-item class="margin-top-large padding" ng-repeat="item in inventoryDetail.distribution">
        <h3 class="row row-center arrow right-bottom-arrow">
          <div class="col">{{ item.store_name }}</div>
				  <div class="col col-fixed">{{ item.qty }} 部</div>
				</h3>
        <ul class="dist-inner-list">
          <li class="row" ng-repeat="wd in item.warehouse_distribution">
				    <div class="col">{{ wd.name }}</div>
				    <div class="col col-fixed">{{ wd.qty }} 部</div>
          </li>
				</ul>
  		</ion-item>
		</ion-list>
	</ion-content>
</ion-view>
